import React, {Component} from 'react';
import {View, Text, Button} from 'react-native';
import NavigationFactory from '../../utils/navigationFactory';

@NavigationFactory
class Page3 extends Component {
  render() {
    const {navigation} = this.props;
    return (
      <View style={{flex: 1, alignItems: 'center', justifyContent: 'center'}}>
        <Text style={{fontSize: 30}}>This is a modal!</Text>
        <Button onPress={() => navigation.goBack()} title="退出模式mode" />
        <Button
          /*  跳转到主页*/
          onPress={() => navigation.navigate('Main',{ screen: 'HomePage' })}
          title="直接跳转到Main"
        />
      </View>
    );
  }
}
export default Page3;
